<html>
<head>
<meta http-equiv="content-type" content="text/html;charset=utf-8">
<link rel="stylesheet" href="./wcart.css" />

<style type="text/css">
.table{width:500px;}
.table td,th{font-size:12px;line-height:30px;border:1px #ccc solid;padding:2px;}
</style>
</head>

<body>
<h1>WCart Demo</h1>


<a href="./index.html">选购产品（产品列表或详情页面）</a>  |<a href="./cart.html">查看购物车</a> 

<table class="table">
<tr><th>产品编码</th><th>产品名称</th><th>产品价格</th><th>包装数量</th><th>数量</th><th>操作</th></tr>

<tr class="wcart_10001"><td>10001</td><td>伊利纯牛奶</td><td>5.00</td><td>12包/箱</td>

<td>
<div class="wcart_change_num">
  <a href="javascript:void(0)" class="wcart_reduce" sku="10001">-</a><input type="text" class="wcart_num" id="num_10001" sku="10001" name="num" value="1">
  <a href="javascript:void(0)" class="wcart_add" sku="10001">+</a></td>
</div>
  <td>
  <a href="javascript:void(0)" sku="10001" price="5.00"  packages="12" class="addwcart">添加</a>
  <a href="javascript:void(0)" sku="10001" class="removewcart">删除</a>
</td></tr>


<tr class="wcart_10002"><td>10002</td><td>蒙牛</td><td>5.00</td><td>12包/箱</td>

<td>
<div class="wcart_change_num">
  <a href="javascript:void(0)" class="wcart_reduce" sku="10002">-</a><input type="text" class="wcart_num" id="num_10002" sku="10002" name="num" value="1">
  <a href="javascript:void(0)" class="wcart_add" sku="10002">+</a></td>
</div>
  <td>
  <a href="javascript:void(0)" sku="10002" price="5.00"  packages="12" class="addwcart">添加</a>
  <a href="javascript:void(0)" sku="10002" class="removewcart">删除</a>
</td></tr>



<tr>
<td>购买数量</td>
<td class="wcart_num"></td>
<td>订购总金额</td>
<td class="wcart_price"></td>
<td><a href="javascript:void(0)" class="wcart_empty">清空购物车</a></td>
  <tr>
</table>


<div class="code"></div>



</body>
</html>

<script src="./lib/jquery-1.11.0.min.js"></script>
<script src="./lib/jquery.cookie.js"></script>
<script src="./wcart.js"></script>
<script>

$(function(){

  wcart.init('buy');
  wcart.mode='cartModel';
  $(".removewcart").show();
  $(".addwcart").hide();
  productModel();
})



</script>
